package cn.csc.module.system.api.dict;

import cn.csc.framework.common.pojo.CommonResult;
import cn.csc.module.system.api.dict.dto.DictDataRespDTO;

import java.util.Collection;

import static cn.csc.framework.common.pojo.CommonResult.success;

/**
 * @author liuchuang
 * @version 1.0
 * @description
 * @date 2023/3/15 17:04
 * @modify
 */
public class DictDataApiFallback implements DictDataApi{


    @Override
    public CommonResult<Boolean> validateDictDatas(String dictType, Collection<String> values) {
        return success(true);
    }

    @Override
    public CommonResult<DictDataRespDTO> getDictData(String dictType, String value) {
        CommonResult<DictDataRespDTO> result = new CommonResult<>();
        DictDataRespDTO dataRespDTO = new DictDataRespDTO();
        dataRespDTO.setDictType("sys_common_status");
        dataRespDTO.setValue("1");
        result.setData(dataRespDTO);
        return result;
    }

    @Override
    public CommonResult<DictDataRespDTO> parseDictData(String dictType, String label) {


        return null;
    }
}
